import React, { Component } from 'react'
import Navbar from './Navbar'

export default class App extends Component {
  render() {
    let obj = {
      title: '其他',
      leftShow: false,
      rightShow: true,
    }
    return (
      <div>
        <div>
          <h1>首页</h1>
          <Navbar
            title='首页'
            leftShow={false}
          ></Navbar>
        </div>
        <div>
          <h1>列表</h1>
          <Navbar
            title='列表'
            leftShow={true}
          ></Navbar>
        </div>
        <div>
          <h1>购物车</h1>
          <Navbar title='购物车'></Navbar>
        </div>
        {/* 简写 和其他属性一起 */}
        <Navbar
          {...obj}
          a='100'
        ></Navbar>
      </div>
    )
  }
}
